Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GQL-31: Create a Mutation for Concept associations #102

Merged
merged 9 commits into from
Mar 21, 2024
Merged

GQL-31: Create a Mutation for Concept associations #102

merged 9 commits into from
Mar 21, 2024

Conversation

dmistry1
Copy link
Contributor

Overview

What is the feature?

Added mutations for associating a Tool, Variable or Service record to a collection record.
Added delete mutation for disassociating a Tool or Service to a collection record.

What areas of the application does this impact?

List impacted areas.

Testing

Reproduction steps

  • Environment for testing:
  • Collection to test with:

Creating association

mutation CreateAssociation($conceptId: String!,$collectionConceptIds: [JSON]!, $conceptType: ConceptType!) {
  createAssociation(conceptId: $conceptId, collectionConceptIds: $collectionConceptIds, nativeId: $nativeId, metadata: $metadata, conceptType: $conceptType) {
    associatedItem
    toolAssociation
  }
}

variables:

"collectionConceptIds": [
    {
      "conceptId": "C1200000051-SEDAC"
    }
  ],
"conceptId": "TL1200000094-MMT_2",
"conceptType": "Tool",

Disassociation

mutation DeleteAssociation($conceptId: String!,$collectionConceptIds: [JSON]!, $conceptType: ConceptType!) {
  deleteAssociation(conceptId: $conceptId, collectionConceptIds: $collectionConceptIds, nativeId: $nativeId, metadata: $metadata, conceptType: $conceptType) {
    associatedItem
    toolAssociation
  }
}

variables:

"collectionConceptIds": [
    {
      "conceptId": "C1200000051-SEDAC"
    }
  ],
"conceptId": "TL1200000094-MMT_2",
"conceptType": "Tool",

Checklist

  • I have added automated tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings

Copy link

codecov bot commented Mar 14, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00%. Comparing base (eb8bb99) to head (c054f20).

Additional details and impacted files
@@            Coverage Diff             @@
##              main      #102    +/-   ##
==========================================
  Coverage   100.00%   100.00%            
==========================================
  Files           81        87     +6     
  Lines         1747      1882   +135     
  Branches       219       222     +3     
==========================================
+ Hits          1747      1882   +135     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@dmistry1 dmistry1 merged commit a60de35 into main Mar 21, 2024
6 checks passed
@dmistry1 dmistry1 deleted the GQL-31 branch March 21, 2024 18:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants